﻿using ExpressesClass.IPrints;
using ExpressesClass.Model;
using ExpressesClass.Util;
using System;
using System.Windows.Forms;

namespace OFFICE_Helper.Util
{
    public class PrintUtil
    {
        public static void Print(string printer, Kddh kddh, int printCur, DateTime now)
        {
            IPrint print = GetIPrint.IGet(kddh, printCur, now);
            if (print != null)
            {
                try
                {
                    print.Print(printer);
                }
                catch
                {
                    MessageBox.Show("打印出错,请重试.", "提示");
                }
            }
        }
    }
}
